/**
 * Copyright (c) 2000-2011 Liferay, Inc. All rights reserved.
 *
 * This library is free software; you can redistribute it and/or modify it under
 * the terms of the GNU Lesser General Public License as published by the Free
 * Software Foundation; either version 2.1 of the License, or (at your option)
 * any later version.
 *
 * This library is distributed in the hope that it will be useful, but WITHOUT
 * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
 * FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public License for more
 * details.
 */

package com.elan.action.model.impl;

import com.elan.action.model.user1;

import com.liferay.portal.kernel.util.StringBundler;
import com.liferay.portal.kernel.util.StringPool;
import com.liferay.portal.model.CacheModel;

import java.io.Serializable;

/**
 * The cache model class for representing user1 in entity cache.
 *
 * @author Elan
 * @see user1
 * @generated
 */
public class user1CacheModel implements CacheModel<user1>, Serializable {
	@Override
	public String toString() {
		StringBundler sb = new StringBundler(7);

		sb.append("{actionId=");
		sb.append(actionId);
		sb.append(", userName=");
		sb.append(userName);
		sb.append(", password=");
		sb.append(password);
		sb.append("}");

		return sb.toString();
	}

	public user1 toEntityModel() {
		user1Impl user1Impl = new user1Impl();

		user1Impl.setActionId(actionId);

		if (userName == null) {
			user1Impl.setUserName(StringPool.BLANK);
		}
		else {
			user1Impl.setUserName(userName);
		}

		if (password == null) {
			user1Impl.setPassword(StringPool.BLANK);
		}
		else {
			user1Impl.setPassword(password);
		}

		user1Impl.resetOriginalValues();

		return user1Impl;
	}

	public long actionId;
	public String userName;
	public String password;
}